/**
 * 
 */
package cn.jy.map.service.impl;

import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import cn.jy.map.domain.achieve.JZAchievements;
import cn.jy.map.domain.achieve.XYFZJX;
import cn.jy.map.domain.achieve.YGJX;
import cn.jy.map.domain.achieve.YLDX;
import cn.jy.map.mapper.JZAchievementsMapper;
import cn.jy.map.service.JZAchievementsService;
import cn.jy.map.utils.MapUtils;
import cn.jy.nvr.datasource.DataSourceConst;
import cn.jy.nvr.datasource.DataSourceContextHolder;

/**
 * @author 刘中斐
 *@date 2018年6月12日 上午10:54:42 
 */
@Service("jZAchievementsService")
public class JZAchievementsServiceImpl implements JZAchievementsService{

	@Autowired
	JZAchievementsMapper jzAchievementsMapper;


	@Override
	public List<JZAchievements> getPulp() {
		DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
		JZAchievements jzAchievements=new JZAchievements();
		List<JZAchievements> jzList=jzAchievementsMapper.getPulpWeight();


		jzList.add(jzAchievements);
		return jzList;
	}

	@Override
	public void insertPulpWeight(JZAchievements jAchievementss) {
		DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
		JZAchievements jzAchievements=new JZAchievements();
		SimpleDateFormat df=new SimpleDateFormat("yyyy");
		String thisDate=df.format(new Date());
		int startTime=Integer.valueOf(thisDate)-2;//前年
		String time=startTime+"-01-01";
		String endTime=startTime+"-01-31";
		int lastTime=Integer.valueOf(thisDate)-1;//去年
		String laststatrTime=lastTime+"-01-01";
		String lastEndTime=lastTime+"-01-31";
		jzAchievements.setLastTwoPulp1((jzAchievementsMapper.getPulp(time, endTime, MapUtils.getThatDate(time, 1, 1), MapUtils.getThatDate(endTime, 1, 1)))/2);
		jzAchievements.setLastTwoPulp2((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,1,2),MapUtils.getThatDate(endTime, 1, 2), MapUtils.getThatDate(laststatrTime, 1, 2), MapUtils.getThatDate(lastEndTime, 1, 2)))/2);
		jzAchievements.setLastTwoPulp3((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,2,2),MapUtils.getThatDate(endTime, 2, 2), MapUtils.getThatDate(laststatrTime, 2, 2), MapUtils.getThatDate(lastEndTime, 2, 2)))/2);
		jzAchievements.setLastTwoPulp4((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,3,2),MapUtils.getThatDate(endTime, 3, 2), MapUtils.getThatDate(laststatrTime, 3, 2), MapUtils.getThatDate(lastEndTime, 3, 2)))/2);
		jzAchievements.setLastTwoPulp5((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,4,2),MapUtils.getThatDate(endTime, 4, 2), MapUtils.getThatDate(laststatrTime, 4, 2), MapUtils.getThatDate(lastEndTime, 4, 2)))/2);
		jzAchievements.setLastTwoPulp6((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,5,2),MapUtils.getThatDate(endTime, 5, 2), MapUtils.getThatDate(laststatrTime, 5, 2), MapUtils.getThatDate(lastEndTime, 5, 2)))/2);
		jzAchievements.setLastTwoPulp7((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,6,2),MapUtils.getThatDate(endTime, 6, 2), MapUtils.getThatDate(laststatrTime, 6, 2), MapUtils.getThatDate(lastEndTime, 6, 2)))/2);
		jzAchievements.setLastTwoPulp8((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,7,2),MapUtils.getThatDate(endTime, 7, 2), MapUtils.getThatDate(laststatrTime, 7, 2), MapUtils.getThatDate(lastEndTime, 7, 2)))/2);
		jzAchievements.setLastTwoPulp9((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,8,2),MapUtils.getThatDate(endTime, 8, 2), MapUtils.getThatDate(laststatrTime, 8, 2), MapUtils.getThatDate(lastEndTime, 8, 2)))/2);
		jzAchievements.setLastTwoPulp10((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,9,2),MapUtils.getThatDate(endTime, 9, 2), MapUtils.getThatDate(laststatrTime, 9, 2), MapUtils.getThatDate(lastEndTime, 9, 2)))/2);
		jzAchievements.setLastTwoPulp11((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,10,2),MapUtils.getThatDate(endTime, 10, 2), MapUtils.getThatDate(laststatrTime, 10, 2), MapUtils.getThatDate(lastEndTime, 10, 2)))/2);
		jzAchievements.setLastTwoPulp12((jzAchievementsMapper.getPulp(MapUtils.getThatDate(time,11,2),MapUtils.getThatDate(endTime, 11, 2), MapUtils.getThatDate(laststatrTime, 11, 2), MapUtils.getThatDate(lastEndTime, 11, 2)))/2);
		String thisYearStartTime=thisDate+"-01-01";
		String thisYeatEndTime=thisDate+"-01-31";
		jzAchievements.setThisYearPulp1(jzAchievementsMapper.getThisYearPulp(thisYearStartTime, thisYeatEndTime));
		jzAchievements.setThisYearPulp2(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 1, 2),MapUtils.getThatDate(thisYeatEndTime, 1, 2)));
		jzAchievements.setThisYearPulp3(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 2, 2),MapUtils.getThatDate(thisYeatEndTime, 2, 2)));
		jzAchievements.setThisYearPulp4(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 3, 2),MapUtils.getThatDate(thisYeatEndTime, 3, 2)));
		jzAchievements.setThisYearPulp5(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 4, 2),MapUtils.getThatDate(thisYeatEndTime, 4, 2)));
		jzAchievements.setThisYearPulp6(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 5, 2),MapUtils.getThatDate(thisYeatEndTime, 5, 2)));
		jzAchievements.setThisYearPulp7(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 6, 2),MapUtils.getThatDate(thisYeatEndTime, 6, 2)));
		jzAchievements.setThisYearPulp8(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 7, 2),MapUtils.getThatDate(thisYeatEndTime, 7, 2)));
		jzAchievements.setThisYearPulp9(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 8, 2),MapUtils.getThatDate(thisYeatEndTime, 8, 2)));
		jzAchievements.setThisYearPulp10(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime,9, 2),MapUtils.getThatDate(thisYeatEndTime, 9, 2)));
		jzAchievements.setThisYearPulp11(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 10, 2),MapUtils.getThatDate(thisYeatEndTime, 10, 2)));
		jzAchievements.setThisYearPulp12(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 11, 2),MapUtils.getThatDate(thisYeatEndTime, 11, 2)));	
		DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		jzAchievementsMapper.insertPulpWeight(jzAchievements);
	}

	/**
	 * 计算全站绩效
	 */
	@Override
	public List<JZAchievements> getPulpWeight() {
		DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		JZAchievements jzAchievements=new JZAchievements();
		List<JZAchievements> list=new ArrayList<JZAchievements>();
		List<JZAchievements> jzList=jzAchievementsMapper.getPulpWeight();
		for (JZAchievements jzAchievements2 : jzList) {

			if (jzAchievements2.getLastTwoPulp1()==jzAchievements2.getThisYearPulp1()) {
				jzAchievements.setThisYearPulp1(jzAchievements2.getLastTwoPulp1()*10);
				jzAchievements.setThisYearPulp2(jzAchievements2.getLastTwoPulp2()*10);
				jzAchievements.setThisYearPulp3(-jzAchievements2.getLastTwoPulp3()*10);
				jzAchievements.setThisYearPulp4(jzAchievements2.getLastTwoPulp4()*10);
				jzAchievements.setThisYearPulp5(jzAchievements2.getLastTwoPulp5()*10);
				jzAchievements.setThisYearPulp6(jzAchievements2.getLastTwoPulp6()*10);
				jzAchievements.setThisYearPulp7(jzAchievements2.getLastTwoPulp7()*10);
				jzAchievements.setThisYearPulp8(jzAchievements2.getLastTwoPulp8()*10);
				jzAchievements.setThisYearPulp9(jzAchievements2.getLastTwoPulp9()*10);
				jzAchievements.setThisYearPulp10(jzAchievements2.getLastTwoPulp10()*10);
				jzAchievements.setThisYearPulp11(jzAchievements2.getLastTwoPulp11()*10);
				jzAchievements.setThisYearPulp12(jzAchievements2.getLastTwoPulp12()*10);
			}
			if (jzAchievements2.getLastTwoPulp1()<jzAchievements2.getThisYearPulp1()) {
				jzAchievements.setThisYearPulp1(((jzAchievements2.getThisYearPulp1()-jzAchievements2.getLastTwoPulp1())*30)+(jzAchievements2.getLastTwoPulp1()*10));
				jzAchievements.setThisYearPulp2(((jzAchievements2.getThisYearPulp2()-jzAchievements2.getLastTwoPulp2())*30)+(jzAchievements2.getLastTwoPulp2()*10));
				jzAchievements.setThisYearPulp3(((jzAchievements2.getThisYearPulp3()-jzAchievements2.getLastTwoPulp3())*30)+(jzAchievements2.getLastTwoPulp3()*10));
				jzAchievements.setThisYearPulp4(((jzAchievements2.getThisYearPulp4()-jzAchievements2.getLastTwoPulp4())*30)+(jzAchievements2.getLastTwoPulp4()*10));
				jzAchievements.setThisYearPulp5(((jzAchievements2.getThisYearPulp5()-jzAchievements2.getLastTwoPulp5())*30)+(jzAchievements2.getLastTwoPulp5()*10));
				jzAchievements.setThisYearPulp6(((jzAchievements2.getThisYearPulp6()-jzAchievements2.getLastTwoPulp6())*30)+(jzAchievements2.getLastTwoPulp6()*10));
				jzAchievements.setThisYearPulp7(((jzAchievements2.getThisYearPulp7()-jzAchievements2.getLastTwoPulp7())*30)+(jzAchievements2.getLastTwoPulp7()*10));
				jzAchievements.setThisYearPulp8(((jzAchievements2.getThisYearPulp8()-jzAchievements2.getLastTwoPulp8())*30)+(jzAchievements2.getLastTwoPulp8()*10));
				jzAchievements.setThisYearPulp9(((jzAchievements2.getThisYearPulp9()-jzAchievements2.getLastTwoPulp9())*30)+(jzAchievements2.getLastTwoPulp9()*10));
				jzAchievements.setThisYearPulp10(((jzAchievements2.getThisYearPulp10()-jzAchievements2.getLastTwoPulp10())*30)+(jzAchievements2.getLastTwoPulp10()*10));
				jzAchievements.setThisYearPulp11(((jzAchievements2.getThisYearPulp11()-jzAchievements2.getLastTwoPulp11())*30)+(jzAchievements2.getLastTwoPulp11()*10));
				jzAchievements.setThisYearPulp12(((jzAchievements2.getThisYearPulp12()-jzAchievements2.getLastTwoPulp12())*30)+(jzAchievements2.getLastTwoPulp12()*10));
			}else {
				jzAchievements.setThisYearPulp1(0);
				jzAchievements.setThisYearPulp2(0);
				jzAchievements.setThisYearPulp3(0);
				jzAchievements.setThisYearPulp4(0);
				jzAchievements.setThisYearPulp5(0);
				jzAchievements.setThisYearPulp6(0);
				jzAchievements.setThisYearPulp7(0);
				jzAchievements.setThisYearPulp8(0);
				jzAchievements.setThisYearPulp9(0);
				jzAchievements.setThisYearPulp10(0);
				jzAchievements.setThisYearPulp11(0);
				jzAchievements.setThisYearPulp12(0);
			}

		}
		//开始计算采浆室绩效
		DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
		SimpleDateFormat df=new SimpleDateFormat("yyyy");
		String thisDate=df.format(new Date());
		String thisYearStartTime=thisDate+"-01-01";
		String thisYeatEndTime=thisDate+"-01-31";
		jzAchievements.setCJSJX1((float)(jzAchievementsMapper.getThisYearPulp(thisYearStartTime, thisYeatEndTime)*7.5)-17310);
		jzAchievements.setCJSJX2((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 1, 2),MapUtils.getThatDate(thisYeatEndTime, 1, 2))*7.5)-17310);
		jzAchievements.setCJSJX3((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 2, 2),MapUtils.getThatDate(thisYeatEndTime, 2, 2))*7.5)-17310);
		jzAchievements.setCJSJX4((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 3, 2),MapUtils.getThatDate(thisYeatEndTime, 3, 2))*7.5)-17310);
		jzAchievements.setCJSJX5((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 4, 2),MapUtils.getThatDate(thisYeatEndTime, 4, 2))*7.5)-17310);
		jzAchievements.setCJSJX6((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 5, 2),MapUtils.getThatDate(thisYeatEndTime, 5, 2))*7.5)-17310);
		jzAchievements.setCJSJX7((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 6, 2),MapUtils.getThatDate(thisYeatEndTime, 6, 2))*7.5)-17310);
		jzAchievements.setCJSJX8((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 7, 2),MapUtils.getThatDate(thisYeatEndTime, 7, 2))*7.5)-17310);
		jzAchievements.setCJSJX9((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 8, 2),MapUtils.getThatDate(thisYeatEndTime, 8, 2))*7.5)-17310);
		jzAchievements.setCJSJX10((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime,9, 2),MapUtils.getThatDate(thisYeatEndTime, 9, 2))*7.5)-17310);
		jzAchievements.setCJSJX11((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 10, 2),MapUtils.getThatDate(thisYeatEndTime, 10, 2))*7.5)-17310);
		jzAchievements.setCJSJX12((float)(jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 11, 2),MapUtils.getThatDate(thisYeatEndTime, 11, 2))*7.5)-17310);

		//血源管理绩效
		jzAchievements.setXYGLJX1((float) ((float)((jzAchievementsMapper.getThisYearPulp(thisYearStartTime, thisYeatEndTime)*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX2((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 1, 2),MapUtils.getThatDate(thisYeatEndTime, 1, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX3((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 2, 2),MapUtils.getThatDate(thisYeatEndTime, 2, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX4((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 3, 2),MapUtils.getThatDate(thisYeatEndTime, 3, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX5((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 4, 2),MapUtils.getThatDate(thisYeatEndTime, 4, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX6((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 5, 2),MapUtils.getThatDate(thisYeatEndTime, 5, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX7((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 6, 2),MapUtils.getThatDate(thisYeatEndTime, 6, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX8((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 7, 2),MapUtils.getThatDate(thisYeatEndTime, 7, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX9((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 8, 2),MapUtils.getThatDate(thisYeatEndTime, 8, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX10((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime,9, 2),MapUtils.getThatDate(thisYeatEndTime, 9, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX11((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 10, 2),MapUtils.getThatDate(thisYeatEndTime, 10, 2))*7.5)-17310) *0.8));
		jzAchievements.setXYGLJX12((float) ((float)((jzAchievementsMapper.getThisYearPulp(MapUtils.getThatDate(thisYearStartTime, 11, 2),MapUtils.getThatDate(thisYeatEndTime, 11, 2))*7.5)-17310) *0.8));

		list.add(jzAchievements);
		return list;
	}


	@Override
	public List<XYFZJX> getNewProviderPulp() {
		DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
		SimpleDateFormat df=new SimpleDateFormat("yyyy");
		String thisDate=df.format(new Date());
		String thisYearStartTime=thisDate+"-01-01";
		String thisYeatEndTime=thisDate+"-01-31";
		List<XYFZJX> list=new ArrayList<XYFZJX>();
		XYFZJX xyfzjx=new XYFZJX();
		//获取2018年每个月新建档的人数
		List<String> cardid=jzAchievementsMapper.getProvider(thisYearStartTime, thisYeatEndTime);
		StringBuilder sb=new StringBuilder();
		for (String string : cardid) {
			sb.append("'"+string+"'"+",");
		}
		List<String> cardid1=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 1,2), MapUtils.getThatDate(thisYeatEndTime, 1, 2));
		StringBuilder sb1=new StringBuilder();
		for (String string : cardid1) {
			sb1.append("'"+string+"'"+",");
		}
		List<String> cardid2=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 2,2), MapUtils.getThatDate(thisYeatEndTime, 2, 2));
		StringBuilder sb2=new StringBuilder();
		for (String string : cardid2) {
			sb2.append("'"+string+"'"+",");
		}
		List<String> cardid3=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 3,2), MapUtils.getThatDate(thisYeatEndTime, 3, 2));
		StringBuilder sb3=new StringBuilder();
		for (String string : cardid3) {
			sb3.append("'"+string+"'"+",");
		}
		List<String> cardid4=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 4,2), MapUtils.getThatDate(thisYeatEndTime, 4, 2));
		StringBuilder sb4=new StringBuilder();
		for (String string : cardid4) {
			sb4.append("'"+string+"'"+",");
		}
		List<String> cardid5=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 5,2), MapUtils.getThatDate(thisYeatEndTime, 5, 2));
		StringBuilder sb5=new StringBuilder();
		for (String string : cardid5) {
			sb5.append("'"+string+"'"+",");
		}
		List<String> cardid6=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 6,2), MapUtils.getThatDate(thisYeatEndTime, 6, 2));
		StringBuilder sb6=new StringBuilder();
		for (String string : cardid6) {
			sb6.append("'"+string+"'"+",");
		}
		List<String> cardid7=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 7,2), MapUtils.getThatDate(thisYeatEndTime, 7, 2));
		StringBuilder sb7=new StringBuilder();
		for (String string : cardid7) {
			sb7.append("'"+string+"'"+",");
		}
		List<String> cardid8=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 8,2), MapUtils.getThatDate(thisYeatEndTime, 8, 2));
		StringBuilder sb8=new StringBuilder();
		for (String string : cardid8) {
			sb8.append("'"+string+"'"+",");
		}
		List<String> cardid9=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 9,2), MapUtils.getThatDate(thisYeatEndTime, 9, 2));
		StringBuilder sb9=new StringBuilder();
		for (String string : cardid9) {
			sb9.append("'"+string+"'"+",");
		}
		List<String> cardid10=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 10,2), MapUtils.getThatDate(thisYeatEndTime, 10, 2));
		StringBuilder sb10=new StringBuilder();
		for (String string : cardid10) {
			sb10.append("'"+string+"'"+",");
		}
		List<String> cardid11=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 11,2), MapUtils.getThatDate(thisYeatEndTime, 11, 2));
		StringBuilder sb11=new StringBuilder();
		for (String string : cardid11) {
			sb11.append("'"+string+"'"+",");
		}
		List<String> cardid12=jzAchievementsMapper.getProvider(MapUtils.getThatDate(thisYearStartTime, 12,2), MapUtils.getThatDate(thisYeatEndTime, 12, 2));
		StringBuilder sb12=new StringBuilder();
		for (String string : cardid12) {
			sb12.append("'"+string+"'"+",");
		}
		//查询新建档的人 有多少被链接了
		DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);

		StringBuilder sBuilder=new StringBuilder();
		if (sb!=null&&sb.length()>0) {
			List<String> providerNo=jzAchievementsMapper.getCardId(sb.toString().substring(0,sb.length()-1));

			for (String string : providerNo) {
				sBuilder.append("'"+string+"'"+",");
			}
		}

		StringBuilder sBuilder1=new StringBuilder();
		if (sb1!=null&&sb.length()>0) {
			List<String> providerNo1=jzAchievementsMapper.getCardId(sb1.toString().substring(0,sb1.length()-1));
			for (String string : providerNo1) {
				sBuilder1.append("'"+string+"'"+",");
			}
		}
		StringBuilder sBuilder2=new StringBuilder();
		if (sb2!=null&&sb2.length()>0) {
			List<String> providerNo2=jzAchievementsMapper.getCardId(sb2.toString().substring(0,sb2.length()-1));

			for (String string : providerNo2) {
				sBuilder2.append("'"+string+"'"+",");
			}
		}
		StringBuilder sBuilder3=new StringBuilder();
		if (sb3!=null&&sb3.length()>0) {
			List<String> providerNo3=jzAchievementsMapper.getCardId(sb3.toString().substring(0,sb3.length()-1));		
			for (String string : providerNo3) {
				sBuilder3.append("'"+string+"'"+",");
			}
		}

		StringBuilder sBuilder4=new StringBuilder();
		if (sb4!=null&&sb4.length()>0) {
			List<String> providerNo4=jzAchievementsMapper.getCardId(sb4.toString().substring(0,sb4.length()-1));
			for (String string : providerNo4) {
				sBuilder4.append("'"+string+"'"+",");
			}

		}

		StringBuilder sBuilder5=new StringBuilder();
		if (sb5!=null&&sb5.length()>0) {
			List<String> providerNo5=jzAchievementsMapper.getCardId(sb5.toString().substring(0,sb5.length()-1));

			for (String string : providerNo5) {
				sBuilder5.append("'"+string+"'"+",");
			}
		}

		StringBuilder sBuilder6=new StringBuilder();
		if (sb6!=null&&sb6.length()>0) {
			List<String> providerNo6=jzAchievementsMapper.getCardId(sb6.toString().substring(0,sb6.length()-1));		
			for (String string : providerNo6) {
				sBuilder6.append("'"+string+"'"+",");
			}
		}
		StringBuilder sBuilder7=new StringBuilder();
		if (sb7!=null&&sb7.length()>0) {
			List<String> providerNo7=jzAchievementsMapper.getCardId(sb7.toString().substring(0,sb7.length()-1));		
			for (String string : providerNo7) {
				sBuilder7.append("'"+string+"'"+",");
			}
		}
		StringBuilder sBuilder8=new StringBuilder();
		if (sb8!=null&&sb8.length()>0) {
			List<String> providerNo8=jzAchievementsMapper.getCardId(sb8.toString().substring(0,sb8.length()-1));			
			for (String string : providerNo8) {
				sBuilder8.append("'"+string+"'"+",");
			}
		}
		StringBuilder sBuilder9=new StringBuilder();
		if (sb9!=null&&sb9.length()>0) {
			List<String> providerNo9=jzAchievementsMapper.getCardId(sb9.toString().substring(0,sb9.length()-1));
			for (String string : providerNo9) {
				sBuilder9.append("'"+string+"'"+",");
			}
		}
		StringBuilder sBuilder10=new StringBuilder();
		if (sb10!=null&&sb10.length()>0) {
			List<String> providerNo10=jzAchievementsMapper.getCardId(sb10.toString().substring(0,sb10.length()-1));		
			for (String string : providerNo10) {
				sBuilder10.append("'"+string+"'"+",");
			}
		}
		StringBuilder sBuilder11=new StringBuilder();
		if (sb11!=null&&sb11.length()>0) {
			List<String> providerNo11=jzAchievementsMapper.getCardId(sb11.toString().substring(0,sb11.length()-1));
			for (String string : providerNo11) {
				sBuilder11.append("'"+string+"'"+",");
			}
		}

		//根据被链接的浆员查询每个月的献浆量
		DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
		if (sBuilder!=null&&sBuilder.length()>0) {
			xyfzjx.setXYFZJX1((jzAchievementsMapper.getNewProviderPulp(sBuilder.toString().substring(0, sBuilder.length()-1), thisYearStartTime, thisYeatEndTime))*15);
		}
		if (sBuilder1!=null&&sBuilder1.length()>0) {
			xyfzjx.setXYFZJX2((jzAchievementsMapper.getNewProviderPulp(sBuilder1.toString().substring(0, sBuilder1.length()-1),MapUtils.getThatDate(thisYearStartTime, 1,2), MapUtils.getThatDate(thisYeatEndTime, 1, 2)))*15);
		}
		if (sBuilder2!=null&&sBuilder2.length()>0) {
			xyfzjx.setXYFZJX3((jzAchievementsMapper.getNewProviderPulp(sBuilder2.toString().substring(0, sBuilder2.length()-1), MapUtils.getThatDate(thisYearStartTime, 2,2), MapUtils.getThatDate(thisYeatEndTime, 2, 2)))*15);
		}
		if (sBuilder3!=null&&sBuilder3.length()>0) {
			xyfzjx.setXYFZJX4((jzAchievementsMapper.getNewProviderPulp(sBuilder3.toString().substring(0, sBuilder3.length()-1),MapUtils.getThatDate(thisYearStartTime, 3,2), MapUtils.getThatDate(thisYeatEndTime, 3, 2)))*15);
		}
		if (sBuilder4!=null&&sBuilder4.length()>0) {
			xyfzjx.setXYFZJX5((jzAchievementsMapper.getNewProviderPulp(sBuilder4.toString().substring(0, sBuilder4.length()-1), MapUtils.getThatDate(thisYearStartTime, 4,2), MapUtils.getThatDate(thisYeatEndTime, 4, 2)))*15);
		}
		if (sBuilder5!=null&&sBuilder5.length()>0) {
			xyfzjx.setXYFZJX6((jzAchievementsMapper.getNewProviderPulp(sBuilder5.toString().substring(0, sBuilder5.length()-1), MapUtils.getThatDate(thisYearStartTime, 5,2), MapUtils.getThatDate(thisYeatEndTime, 5, 2)))*15);
		}
		if (sBuilder6!=null&&sBuilder6.length()>0) {
			xyfzjx.setXYFZJX7((jzAchievementsMapper.getNewProviderPulp(sBuilder6.toString().substring(0, sBuilder6.length()-1), MapUtils.getThatDate(thisYearStartTime, 6,2), MapUtils.getThatDate(thisYeatEndTime, 6, 2)))*15);
		}
		if (sBuilder7!=null&&sBuilder7.length()>0) {
			xyfzjx.setXYFZJX8((jzAchievementsMapper.getNewProviderPulp(sBuilder7.toString().substring(0, sBuilder7.length()-1), MapUtils.getThatDate(thisYearStartTime, 7,2), MapUtils.getThatDate(thisYeatEndTime, 7, 2)))*15);
		}
		if (sBuilder8!=null&&sBuilder8.length()>0) {
			xyfzjx.setXYFZJX9((jzAchievementsMapper.getNewProviderPulp(sBuilder8.toString().substring(0, sBuilder8.length()-1), MapUtils.getThatDate(thisYearStartTime, 8,2), MapUtils.getThatDate(thisYeatEndTime, 8, 2)))*15);
		}
		if (sBuilder9!=null&&sBuilder9.length()>0) {
			xyfzjx.setXYFZJX10((jzAchievementsMapper.getNewProviderPulp(sBuilder9.toString().substring(0, sBuilder9.length()-1), MapUtils.getThatDate(thisYearStartTime, 9,2), MapUtils.getThatDate(thisYeatEndTime, 9, 2)))*15);
		}
		if (sBuilder10!=null&&sBuilder10.length()>0) {
			xyfzjx.setXYFZJX11((jzAchievementsMapper.getNewProviderPulp(sBuilder10.toString().substring(0, sBuilder10.length()-1), MapUtils.getThatDate(thisYearStartTime, 10,2), MapUtils.getThatDate(thisYeatEndTime, 10, 2)))*15);
		}
		if (sBuilder11!=null&&sBuilder11.length()>0) {
			xyfzjx.setXYFZJX12((jzAchievementsMapper.getNewProviderPulp(sBuilder11.toString().substring(0, sBuilder11.length()-1), MapUtils.getThatDate(thisYearStartTime, 11,2), MapUtils.getThatDate(thisYeatEndTime, 11, 2)))*15);
		}

		list.add(xyfzjx);
		return list;
	}


	@Override
	public List<YGJX> getLinkPulp() {
		List<YGJX> ygList=new ArrayList<YGJX>();
		DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
		SimpleDateFormat df=new SimpleDateFormat("yyyy");
		String thisDate=df.format(new Date());
		String thisYearStartTime=thisDate+"-01-01";
		String thisYeatEndTime=thisDate+"-01-31";
		List<String> cardid1=jzAchievementsMapper.getCollProvider(thisYearStartTime, thisYeatEndTime);
		List<String> cardid2=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 1, 2), MapUtils.getThatDate(thisYeatEndTime, 1, 2));
		List<String> cardid3=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 2, 2), MapUtils.getThatDate(thisYeatEndTime, 2, 2));
		List<String> cardid4=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 3, 2), MapUtils.getThatDate(thisYeatEndTime, 3, 2));
		List<String> cardid5=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 4, 2), MapUtils.getThatDate(thisYeatEndTime, 4, 2));
		List<String> cardid6=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 5, 2), MapUtils.getThatDate(thisYeatEndTime, 5, 2));
		List<String> cardid7=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 6, 2), MapUtils.getThatDate(thisYeatEndTime, 6, 2));
		List<String> cardid8=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 7, 2), MapUtils.getThatDate(thisYeatEndTime, 7, 2));
		List<String> cardid9=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 8, 2), MapUtils.getThatDate(thisYeatEndTime, 8, 2));
		List<String> cardid10=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 9, 2), MapUtils.getThatDate(thisYeatEndTime, 9, 2));
		List<String> cardid11=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 10, 2), MapUtils.getThatDate(thisYeatEndTime, 10, 2));
		List<String> cardid12=jzAchievementsMapper.getCollProvider(MapUtils.getThatDate(thisYearStartTime, 11, 2), MapUtils.getThatDate(thisYeatEndTime, 11, 2));
		DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		YGJX ygjx=new YGJX();
		if (cardid1!=null&&cardid1.size()>0) {
			List<String> providerNo1=jzAchievementsMapper.getLinkProvider(cardid1);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);	
			ygjx.setYGJX1((jzAchievementsMapper.getLinkPulp(providerNo1,thisYearStartTime,thisYeatEndTime))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);	
		}
		if (cardid2!=null&&cardid2.size()>0) {			
			List<String> providerNo2=jzAchievementsMapper.getLinkProvider(cardid2);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);	
			ygjx.setYGJX2((jzAchievementsMapper.getLinkPulp(providerNo2,MapUtils.getThatDate(thisYearStartTime, 1, 2), MapUtils.getThatDate(thisYeatEndTime, 1, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid3!=null&&cardid3.size()>0) {
			List<String> providerNo3=jzAchievementsMapper.getLinkProvider(cardid3);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
			ygjx.setYGJX3((jzAchievementsMapper.getLinkPulp(providerNo3,MapUtils.getThatDate(thisYearStartTime, 2, 2), MapUtils.getThatDate(thisYeatEndTime, 2, 2)))*100);
			
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid4!=null&&cardid4.size()>0) {
			List<String> providerNo4=jzAchievementsMapper.getLinkProvider(cardid4);
			
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
			ygjx.setYGJX4((jzAchievementsMapper.getLinkPulp(providerNo4,MapUtils.getThatDate(thisYearStartTime, 3, 2), MapUtils.getThatDate(thisYeatEndTime, 3, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid5!=null&&cardid5.size()>0) {
			List<String> providerNo5=jzAchievementsMapper.getLinkProvider(cardid5);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);	
			
			ygjx.setYGJX5((jzAchievementsMapper.getLinkPulp(providerNo5,MapUtils.getThatDate(thisYearStartTime, 4, 2), MapUtils.getThatDate(thisYeatEndTime, 4, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid6!=null&&cardid6.size()>0) {
			List<String> providerNo6=jzAchievementsMapper.getLinkProvider(cardid6);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
			ygjx.setYGJX6((jzAchievementsMapper.getLinkPulp(providerNo6,MapUtils.getThatDate(thisYearStartTime, 5, 2), MapUtils.getThatDate(thisYeatEndTime, 5, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid7!=null&&cardid7.size()>0) {
			List<String> providerNo7=jzAchievementsMapper.getLinkProvider(cardid7);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);	
			ygjx.setYGJX7((jzAchievementsMapper.getLinkPulp(providerNo7,MapUtils.getThatDate(thisYearStartTime, 6, 2), MapUtils.getThatDate(thisYeatEndTime, 6, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid8!=null&&cardid8.size()>0) {
			List<String> providerNo8=jzAchievementsMapper.getLinkProvider(cardid8);
			ygjx.setYGJX8((jzAchievementsMapper.getLinkPulp(providerNo8,MapUtils.getThatDate(thisYearStartTime, 7, 2), MapUtils.getThatDate(thisYeatEndTime, 7, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);	
		}
		if (cardid9!=null&&cardid9.size()>0) {
			List<String> providerNo9=jzAchievementsMapper.getLinkProvider(cardid9);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
			ygjx.setYGJX9((jzAchievementsMapper.getLinkPulp(providerNo9,MapUtils.getThatDate(thisYearStartTime, 8, 2), MapUtils.getThatDate(thisYeatEndTime, 8, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid10!=null&&cardid10.size()>0) {
			List<String> providerNo10=jzAchievementsMapper.getLinkProvider(cardid10);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);	
			ygjx.setYGJX10((jzAchievementsMapper.getLinkPulp(providerNo10,MapUtils.getThatDate(thisYearStartTime, 9, 2), MapUtils.getThatDate(thisYeatEndTime, 9, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid11!=null&&cardid11.size()>0) {
			List<String> providerNo11=jzAchievementsMapper.getLinkProvider(cardid11);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);	
			ygjx.setYGJX11((jzAchievementsMapper.getLinkPulp(providerNo11,MapUtils.getThatDate(thisYearStartTime, 10, 2), MapUtils.getThatDate(thisYeatEndTime, 10, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}
		if (cardid12!=null&&cardid12.size()>0) {
			List<String> providerNo12=jzAchievementsMapper.getLinkProvider(cardid12);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
			ygjx.setYGJX12((jzAchievementsMapper.getLinkPulp(providerNo12,MapUtils.getThatDate(thisYearStartTime, 11, 2), MapUtils.getThatDate(thisYeatEndTime, 11, 2)))*100);
			DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		}

		ygList.add(ygjx);
		return ygList;
	}


	@Override
	public List<YLDX> getYLDX() {
		DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		SimpleDateFormat df=new SimpleDateFormat("yyyy");
		String thisDate=df.format(new Date());
		YLDX yldx=new YLDX();
		List<YLDX> list=new ArrayList<YLDX>();
		String thisYearStartTime=thisDate+"-01-01";
		String thisYeatEndTime=thisDate+"-01-31";
		 List<String> yldxCardId1 = jzAchievementsMapper.getYLDXCardId(thisYearStartTime, thisYeatEndTime);
		 List<String> yldxCardId2 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 1, 2), MapUtils.getThatDate(thisYeatEndTime, 1, 2));
		 List<String> yldxCardId3 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 2, 2), MapUtils.getThatDate(thisYeatEndTime, 2, 2));
		 List<String> yldxCardId4 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 3, 2), MapUtils.getThatDate(thisYeatEndTime, 3, 2));
		 List<String> yldxCardId5 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 4, 2), MapUtils.getThatDate(thisYeatEndTime, 4, 2));
		 List<String> yldxCardId6 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 5, 2), MapUtils.getThatDate(thisYeatEndTime, 5, 2));
		 List<String> yldxCardId7 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 6, 2), MapUtils.getThatDate(thisYeatEndTime, 6, 2));
		 List<String> yldxCardId8 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 7, 2), MapUtils.getThatDate(thisYeatEndTime, 7, 2));
		 List<String> yldxCardId9 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 8, 2), MapUtils.getThatDate(thisYeatEndTime, 8, 2));
		 List<String> yldxCardId10 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 9, 2), MapUtils.getThatDate(thisYeatEndTime, 9, 2));
		 List<String> yldxCardId11 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 10, 2), MapUtils.getThatDate(thisYeatEndTime, 10, 2));
		 List<String> yldxCardId12 = jzAchievementsMapper.getYLDXCardId(MapUtils.getThatDate(thisYearStartTime, 11, 2), MapUtils.getThatDate(thisYeatEndTime, 11, 2));
		 if (yldxCardId1!=null&&yldxCardId1.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
			yldx.setYLDX1(jzAchievementsMapper.getLinkPulps(yldxCardId1, thisYearStartTime, thisYeatEndTime)*100);
		}
		 if (yldxCardId2!=null&&yldxCardId2.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX2(jzAchievementsMapper.getLinkPulps(yldxCardId2, MapUtils.getThatDate(thisYearStartTime, 1, 2), MapUtils.getThatDate(thisYeatEndTime, 1, 2))*100);
		}
		 if (yldxCardId3!=null&&yldxCardId3.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX3(jzAchievementsMapper.getLinkPulps(yldxCardId3, MapUtils.getThatDate(thisYearStartTime, 2, 2), MapUtils.getThatDate(thisYeatEndTime, 2, 2))*100);
		}
		 if (yldxCardId4!=null&&yldxCardId4.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX4(jzAchievementsMapper.getLinkPulps(yldxCardId4, MapUtils.getThatDate(thisYearStartTime, 3, 2), MapUtils.getThatDate(thisYeatEndTime, 3, 2))*100);
		}
		 if (yldxCardId5!=null&&yldxCardId5.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX5(jzAchievementsMapper.getLinkPulps(yldxCardId5, MapUtils.getThatDate(thisYearStartTime, 4, 2), MapUtils.getThatDate(thisYeatEndTime, 4, 2))*100);
		}
		 if (yldxCardId6!=null&&yldxCardId6.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX6(jzAchievementsMapper.getLinkPulps(yldxCardId6, MapUtils.getThatDate(thisYearStartTime, 5, 2), MapUtils.getThatDate(thisYeatEndTime, 5, 2))*100);
		}
		 if (yldxCardId7!=null&&yldxCardId7.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX7(jzAchievementsMapper.getLinkPulps(yldxCardId7, MapUtils.getThatDate(thisYearStartTime, 6, 2), MapUtils.getThatDate(thisYeatEndTime, 6, 2))*100);
		}
		 if (yldxCardId8!=null&&yldxCardId8.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX8(jzAchievementsMapper.getLinkPulps(yldxCardId8, MapUtils.getThatDate(thisYearStartTime, 7, 2), MapUtils.getThatDate(thisYeatEndTime, 7, 2))*100);
		}
		 if (yldxCardId9!=null&&yldxCardId9.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX9(jzAchievementsMapper.getLinkPulps(yldxCardId9, MapUtils.getThatDate(thisYearStartTime, 8, 2), MapUtils.getThatDate(thisYeatEndTime, 8, 2))*100);
		}
		 if (yldxCardId10!=null&&yldxCardId10.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX10(jzAchievementsMapper.getLinkPulps(yldxCardId10, MapUtils.getThatDate(thisYearStartTime, 9, 2), MapUtils.getThatDate(thisYeatEndTime, 9, 2))*100);
		}
		 if (yldxCardId11!=null&&yldxCardId11.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX11(jzAchievementsMapper.getLinkPulps(yldxCardId1, MapUtils.getThatDate(thisYearStartTime, 10, 2), MapUtils.getThatDate(thisYeatEndTime, 10, 2))*100);
		}
		 if (yldxCardId12!=null&&yldxCardId12.size()>0) {
			 DataSourceContextHolder.setDataSourceType(DataSourceConst.jingying);
				yldx.setYLDX12(jzAchievementsMapper.getLinkPulps(yldxCardId12, MapUtils.getThatDate(thisYearStartTime, 11, 2), MapUtils.getThatDate(thisYeatEndTime, 11, 2))*100);
		}
		 
		 list.add(yldx);
		
		return list;
	}


	@Override
	public List<JZAchievements> selectPulp() {
		DataSourceContextHolder.setDataSourceType(DataSourceConst.mx);
		return jzAchievementsMapper.getPulpWeight();
	}


	@Override
	public void deletePulpWeight() {
		jzAchievementsMapper.deletePulpWeight();
		
	}

}
